package com.feeyo.monitor.utils;

/**
 * @Author <a href="mailto:bliulei@variflight.com">liulei</a>
 * @Description Created by liulei on 2017/6/7 下午1:09.
 */
public class CoordTransform {
    public static double[] latlonToEPSG3857 (double lat, double lon){
        double x = lon * 20037508.34 / 180;
        double y = Math.log(Math.tan((90 + lat) * Math.PI / 360)) / (Math.PI / 180);
        y = y * 20037508.34 / 180;
        return new double[]{y,x};
    }
}
